Unsung Tools of DevOps by Jonathan Thurman
Author:Jonathan Thurman
Language: eng
Format: mobi, epub
Tags: COMPUTERS / Software Development & Engineering / Tools
ISBN: 9781449367015
Publisher: O’Reilly Media
Published: 2013-11-19T05:00:00+00:00
IPerf
A network can be a weird place, with ever-changing asymmetric paths moving bits from one place to another. Sometimes this leads to very different throughput performance between servers that appear to be otherwise identical. After running a few common utilities like traceroute — or perhaps curl on an HTTP service — you are still unable to replicate the problem.
Enter iperf, the network testing tool. Iperf is designed to measure the throughput between two points and runs as a client/server pair. It supports both UDP and TCP and can either test bidirectionally or unidirectionally from each endpoint in a single command. The power of iperf is how efficiently it is able to saturate a network connection. For TCP, it reports the overall throughput. For UDP, you can adjust the datagram size and the report includes throughput, packet loss, and jitter.
Installation is easy, as the package exists in most major Linux distributions and is supported for cross-platform compiling, and Windows binaries are available from third parties. To run iperf, you do need to have your firewall configured to allow connections between the two endpoints, with the default server port for TCP and UDP being 5001. You also need to have iperf running on both sides of the connection to test. Iperf can either run in Server or Client mode, one on each end of the connection, as in the following examples.
TCP Server Mode
$ iperf -s ----------------------------------------------------------- Server listening on TCP port 5001 TCP window size: 85.3 KByte (default) ----------------------------------------------------------- [ 4] local 192.168.1.101 port 5001 connected with 192.168.1.100 port 43697 [ ID] Interval Transfer Bandwidth [ 4] 0.0-10.1 sec 114 MBytes 94.1 Mbits/sec
TCP Client Mode
$ iperf -c 192.168.1.101 ----------------------------------------------------------- Client connecting to 192.168.1.101, TCP port 5001 TCP window size: 22.9 KByte (default) ----------------------------------------------------------- [ 3] local 192.168.1.100 port 43697 connected with 192.168.1.101 port 5001 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 114 MBytes 95.0 Mbits/sec
Performing an initial TCP test with iperf requires starting the server, then firing the client at it. In the above example, a Raspberry Pi is running as the server, with another system sending traffic to it. The end result is the complete throughput as measured from the client to the server. You can optionally measure both directions one at a time with the -r flag, or run both directions at the same time with the -d flag passed to the client. Which method to use depends on your expected workload, but in general you should get statistically similar results from the independent tests when each system is running on similar hardware.
UDP Server Mode
$ iperf -s -u ----------------------------------------------------------- Server listening on UDP port 5001 Receiving 1470 byte datagrams UDP buffer size: 160 KByte (default) ----------------------------------------------------------- [ 3] local 192.168.1.101 port 5001 connected with 192.168.1.100 port 55272 [ ID] Interval Transfer Bandwidth Jitter Lost/Total [ 3] 0.0-10.0 sec 114 MB 95.7 Mbps 0.158 ms 0/81482 [ 3] 0.0-10.0 sec 1 datagrams received out-of-order
UDP Client Mode
$ iperf -u -c 192.168.1.101 ----------------------------------------------------------- Client connecting to 192.168.1.101, UDP port 5001 Sending
Download
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
The Mikado Method by Ola Ellnestam Daniel Brolund(25294)
Hello! Python by Anthony Briggs(24339)
Secrets of the JavaScript Ninja by John Resig Bear Bibeault(23434)
Kotlin in Action by Dmitry Jemerov(22512)
The Well-Grounded Java Developer by Benjamin J. Evans Martijn Verburg(21976)
Dependency Injection in .NET by Mark Seemann(21849)
OCA Java SE 8 Programmer I Certification Guide by Mala Gupta(20715)
Algorithms of the Intelligent Web by Haralambos Marmanis;Dmitry Babenko(19524)
Grails in Action by Glen Smith Peter Ledbrook(18609)
Adobe Camera Raw For Digital Photographers Only by Rob Sheppard(17034)
Sass and Compass in Action by Wynn Netherland Nathan Weizenbaum Chris Eppstein Brandon Mathis(15843)
Secrets of the JavaScript Ninja by John Resig & Bear Bibeault(13697)
Test-Driven iOS Development with Swift 4 by Dominik Hauser(11857)
Jquery UI in Action : Master the concepts Of Jquery UI: A Step By Step Approach by ANMOL GOYAL(11151)
A Developer's Guide to Building Resilient Cloud Applications with Azure by Hamida Rebai Trabelsi(10627)
Hit Refresh by Satya Nadella(9202)
The Kubernetes Operator Framework Book by Michael Dame(8570)
Exploring Deepfakes by Bryan Lyon and Matt Tora(8415)
Robo-Advisor with Python by Aki Ranin(8361)